// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router'
// import BootstrapVue from 'bootstrap-vue'
// import 'bootstrap/dist/css/bootstrap.css'
// import 'bootstrap-vue/dist/bootstrap-vue.css'
import { Icon } from 'vant';
import { NavBar } from 'vant';
import { Sidebar, SidebarItem } from 'vant';
import { Image as VanImage } from 'vant';
import { Cell, CellGroup } from 'vant';
import { Button } from 'vant';
import 'vant/lib/index.css';
import { Collapse, CollapseItem } from 'vant';
import { Form } from 'vant';
import { Field } from 'vant';
import { DropdownMenu, DropdownItem } from 'vant';
import { List } from 'vant';
import { Notify } from 'vant';
import { Search } from 'vant';
import { Card } from 'vant';
import { Popover } from 'vant';
import { ActionSheet } from 'vant';
import { Checkbox, CheckboxGroup } from 'vant';
import { Tabbar, TabbarItem } from 'vant';
import { Stepper } from 'vant';
import { RadioGroup, Radio } from 'vant';
import { Grid, GridItem } from 'vant';
import { Dialog } from 'vant';

import ElementUI from 'element-ui';
Vue.use(ElementUI);
import 'element-ui/lib/theme-chalk/index.css';
import {Container} from 'element-ui';
import {menu} from 'element-ui';
import {Card as ElementCard} from 'element-ui';
import { Message } from 'element-ui';
import axios from 'axios';

const API_BASE_URL = process.env.NODE_ENV === 'production'
  ? process.env.API_BASE_URL
  : 'http://localhost:8080';

axios.defaults.baseURL = API_BASE_URL;

Vue.prototype.$message = Message;
Vue.use(ElementCard);
Vue.use(menu);
Vue.use(Container);
// 全局注册
Vue.use(Dialog);
Vue.use(Grid);
Vue.use(GridItem);
Vue.use(Tabbar);
Vue.use(TabbarItem);
// import axios from 'axios';
import store from './store/index';
Vue.config.productionTip = false
Vue.use(Stepper);
Vue.use(Radio);
Vue.use(RadioGroup);
// Vue.use(axios);
Vue.use(Checkbox);
Vue.use(CheckboxGroup);
Vue.use(ActionSheet);
Vue.use(Popover);
Vue.use(Card);
Vue.use(Search);
Vue.use(Notify);
Vue.use(List);
Vue.use(DropdownMenu);
Vue.use(DropdownItem);
Vue.use(Form);
Vue.use(Field);
Vue.use(Collapse);
Vue.use(CollapseItem);
Vue.use(Button);
Vue.use(Cell);
Vue.use(CellGroup);
Vue.use(VanImage);
Vue.use(Sidebar);
Vue.use(SidebarItem);
Vue.use(NavBar);
Vue.use(Icon);
// Vue.use(BootstrapVue)
Vue.config.productionTip = false

/* eslint-disable no-new */
new Vue({
  el: '#app',
  router,
  components: { App },
  template: '<App/>',
  store,
})
